Allow unknown root directory.
authorSamuel Thibault <samuel.thibault@ens-lyon.org>
Sat, 29 Dec 2018 10:04:27 +0000 (10:04 +0000)
committerAurelien Jarno <aurel32@debian.org>
Sat, 29 Dec 2018 10:04:27 +0000 (10:04 +0000)
commita0bcd0bf2bd4d145311196744ee97f5b65ed6954
treee402971d17bf5f9cd9189dc4ade36b0e4c4b1000
parent073391e54ab70a4a574792159b11fa0489442575
Allow unknown root directory.

To be efficient, the remap translator simply returns ports from the underlying
filesystem, and thus the root directory found through browsing '..' is the
underlying root, not the remap root. This should not be a reason for getcwd to
fail.

* sysdeps/mach/hurd/getcwd.c (_hurd_canonicalize_directory_name_internal): Do
not remove the heading slash if we got an unknown root directory.
(__getcwd): Do not fail with EGRATUITOUS if we got an unknown root directory.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Gbp-Pq: Topic hurd-i386
Gbp-Pq: Name tg-remap_getcwd.diff
sysdeps/mach/hurd/getcwd.c